function Greet(props) {
    const handleClick = (e) => {
        console.log(e)
        alert('你被点击了')
    }
    return <>
        <button onClick={(e) => { console.log(e); alert('我被点击了') }}>点我</button>
        <button onClick={handleClick}>点你</button>
        {/* e.target.value是输入框内用户输入的值 */}
        <input type="text" onChange={(e) => { console.log(e.target.value) }} />
    </>
}

export default Greet;